package com.wwm.springcloud.authservice.common;

import java.util.UUID;

public class PasswordUtils {

    public static String getUuid() {
        return UUID.randomUUID().toString().replaceAll("-", "");
    }

    public static String getUuidPasswd(String passwd, String uuid) {
        if (ToolUtils.isNull(uuid)) {
            return Encrypt.md5AndSha(passwd + uuid);
        } else {
            return Encrypt.md5AndSha(passwd);
        }
    }
}
